package com.wtwd.device.constant;

import com.wtwd.common.base.model.BaseRespCode;

/**
 * 返回状态码枚举
 */
public enum RespCode implements BaseRespCode {
    FAILED(0, "failed"), //失败
    SUCCESS(1, "success"),//成功
    TOKEN_UNAUTHORIZED(502, "token授权失败"),
    USER_NAME_OR_PASSWORD_ERROR(601,"用户名或者密码错误"),
    USER_EXIST(601,"已经存在该用户名用户"),
    NO_PERMISSION(602,"无权操作"),
    NO_PARAM(604,"参数不能为空"),
    ERROE_WATCHID(604,"手表id错误"),
    WATCH_ID_REPEAT(1000,"手表ID已存在,请重新输入"),
    NO_RIGHT_OPERATION(1001,"无权操作"),
    DIAL_PLATE_ORDER_REPEAT(1002,"表盘顺序已存在"),
    DIAL_PLATE_NOT_EXIST(1003,"表盘不存在"),
    WATCH_NOT_EXIST(1004,"手表不存在"),
    LANGUAGE_REPEAT(1010,"语言类型重复"),
    UPGRADE_REPEAT(1011,"该版本已存在升级包")
    ,DIAL_PLATE_EXIST(1005,"表盘已经存在")
    ,CUSTOMER_EXIST_DEVICE(2001,"客户存在设备")
    ,CUSTOMER_EXIST(2002,"客户已存在")
    ,GETWAEWARY_timeout(5003,"连接超时,请重新")
    ,CUSTOMER_NOT_EXIST(6001,"请输入正确且完整的客户名称")
    ,CUSTOMER_NOT_DEVICE(6002,"该客户并无设备导出")
    ,APP_NAME_REPEAT(7001,"App名称不能重复")
    ,APP_VERSION_REPEAT(7002,"app版本不能重复")
    ,DATA_DISORDER(7003,"数据错乱，请联系管理员查看原因")
    ,APP_VSERSION_NOT_INIT(7004,"APP版本尚未初始化")
    ,GROPU_NAME_EXIST(7005,"分组名称已经存在")
    ,IMPORT_FILE_EXCEED_MAX(7006,"单次导入文件不能超过100000条")
    ,WATCH_ID_IS_EXIST_RELEVANCY(7007,"当前手表id与表盘文件或升级文件存在关联性,暂不允许更换")
    ,HEALTH_TYPE_NAME(8000,"当前健康类型已经存在")

    ,NO_PARAMETERS(9001,"数据验证异常:参数不能为空")
    ,NO_SPECIFICATIOS(9002,"数据验证异常:不符合规范")
    ,START_MORE_END(9003,"数据验证异常:起始数据应小于结束数据")

    ;


    private int code;
    private String msg;

    RespCode(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }
}
